#include "FPCH.h"

#include "FLog.h"

#include <time.h>

namespace Font
{

	Log::Log()
	{

	}
	
	Log::~Log()
	{
		
	}

	void Log::Message(int a_Severity, const char* a_File, unsigned int a_CodeLine, const char* a_Function, const char* a_Message, ...)
	{
		va_list arg_list;
		va_start(arg_list, a_Message);
		char msg_buffer[0xFFFF];
		vsnprintf(msg_buffer, 0xFFFF, a_Message, arg_list);
		va_end(arg_list);

		time_t raw_time;
		struct tm timeinfo;
		time(&raw_time);
		localtime_s(&timeinfo, &raw_time);

		char time_buffer[0xFFFF];
		sprintf(time_buffer, "%02d:%02d:%02d", timeinfo.tm_hour, timeinfo.tm_min, timeinfo.tm_sec);

		const char* file_short = strrchr(a_File, ' \\') + 1;

		//m_Callback(a_Severity, msg_buffer, time_buffer, file_short, a_CodeLine);
	}

}; // namespace Font